/*
 * Created on 13/11/2012 - 12:51 PM
 */
package sembr.vtk.reader;

import vtk.vtkPolyData;
import vtk.vtkSTLReader;

/**
 *
 * @author adriano
 */
public class StlReader extends ReaderBase
{
    private vtkSTLReader reader;
    
    public StlReader(String filePath)
    {
        super.setFilePath(filePath); 
        reader = new vtkSTLReader();
        processDataFromReader();
    }
    
    private void processDataFromReader()
    {
        reader.SetFileName(super.getFilePath());
        reader.Update();
    } 

    @Override
    public vtkPolyData getPolyData() 
    {
        return reader.GetOutput();
    }
    
}
